const {defineConfig} = require('@vue/cli-service')

const path = require('path')

function resolve(dir) { // 声明一个函数,调用函数的时候传入相对路径
  return path.join(__dirname, dir) // return绝对路径
}

module.exports = defineConfig({
  transpileDependencies: true,
  configureWebpack: {
    resolve: {
      alias: {
        '@': resolve('src')
      }
    },
    experiments: {
      topLevelAwait: true
    }
  }
})
